package com.tuanzi.loan.business.service.workflow.impl;

import com.tuanzi.loan.business.entity.workflow.ActHiProcinst;
import com.tuanzi.loan.business.repository.workflow.ActHiProcinstRepository;
import com.tuanzi.loan.business.service.workflow.ActHiProcinstService;
import com.tuanzi.loan.core.aspect.Debug;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.retry.RetryException;
import org.springframework.retry.annotation.Retryable;
import org.springframework.stereotype.Service;

import java.util.Date;
import java.util.List;

/**
 * User: liangZongXi
 * Create time: 20:04 2018/4/20
 * Description:
 */
@Debug
@Service
@Retryable(value = { RetryException.class })
public class ActHiProcinstServiceImpl implements ActHiProcinstService{
    @Autowired
    private ActHiProcinstRepository actHiProcinstRepository;
    @Override
    public List<ActHiProcinst> findActHiProcinstsByStartTimeGreaterThanEqualAndStartTimeIsLessThanEqualAndBusinessKeyStartsWith
            (Date startDate, Date endDate, String businessKeyLike) {
        return actHiProcinstRepository.findActHiProcinstsByStartTimeGreaterThanEqualAndStartTimeIsLessThanEqualAndBusinessKeyStartsWith(startDate, endDate,businessKeyLike);
    }
}
